ExamPlay Light Logo
दाखिल करना

Computer Science for IGCSE & O level - Programming (Section 16 - No. 13)

What would be the outcome if the `answer` variable is given the value "*" in a case statement where cases are defined for '+', '-', '*' and '/', but no default case is available?
The code block corresponding to the '*' case would be executed.
The code block for the '+' case would be executed.
No code block would be executed.
The program would exit with an error.

स्पष्टीकरण

The program will search for a match. Because the '*' is a value in the cases, the code block will execute.

टिप्पणियाँ (0)

टिप्पणी करने के लिए लॉगिन करें
विज्ञापन
BrainBehindX Inc Logo
©2026; द्वारा संचालित BrainBehindX Inc